#define  _CRT_SECURE_NO_WARNINGS 1		
#include <stdio.h>
#include<string.h>
int main() {
    char arr[501];
    gets(arr);
    int len = strlen(arr);
    int count = 0;
    for (int i = 0; i < len - 1; i++)
    {
        int j = 0;
        for (j = 0; j < len - i - 1; j++)
        {
            if (arr[j] > arr[j + 1])
            {
                char tmp = arr[j];
                arr[j] = arr[j + 1];
                arr[j + 1] = tmp;
            }
        }
    }
    for (int i = 0; i < len; i++)
    {
        if (arr[i] != arr[i + 1])
        {
            count++;
        }
    }
    printf("%d", count);
    return 0;
}

